<h4 class="sets">EDITING SET <%=h @fset.name %>
<% if @fset.public %>
  <span id="private1"><%= link_to_remote "This set is public. Make Private", :url => { :action => "toggle_public_private", :id => @fset.id }, :html => {:class => "pp", :onclick=>'Effect.Appear("public");Effect.toggle("private")', :id => :private}  %></span>
  <span id="public2"><%= link_to_remote "This set is private. Make Public", :url => { :action => "toggle_public_private", :id => @fset.id }, :html => {:class => "pp", :onclick=>'Effect.Appear("private");Effect.toggle("public")', :style=>"display: none;", :id => :public} %>
<% else %>
  <span id="private1"><%= link_to_remote "This set is public. Make Private", :url => { :action => "toggle_public_private", :id => @fset.id }, :html => {:class => "pp", :onclick=>'Effect.Appear("public");Effect.toggle("private")', :style=>"display: none;", :id => :private}  %></span>
  <span id="public2"><%= link_to_remote "This is set is private. Make Public", :url => { :action => "toggle_public_private", :id => @fset.id }, :html => {:class => "pp", :onclick=>'Effect.Appear("private");Effect.toggle("public")', :id => :public} %>
<% end %>
</h4>
    	
<% form_for(@fset) do |f| %>
  <%= f.error_messages %>

<% end %>
<div class="stats_control">
<ul>

	<li><%= link_to '', fplay_fset_url(@fset), { :class => "play" } %></li>
	<li><%= link_to '', just_wrong_fset_url(@fset), { :class => "play_wrong" } %></li>
	<li><%= link_to '', until_correct_fset_url(@fset), { :class => "play_until" } %></li>
	</ul><div class="stars"><%= ratings_for @fset %></div>
	<div class="clear">&nbsp;</div>
</div>

<div id="create">

  <%= render :partial => 'flashcards/new_part', :locals=> { :fset => @fset, :new_flashcard => @new_flashcard } %>

</div>

<div id="flashcards_container">
<% for flashcard in @flashcards %>
	<div id="fc_<%=flashcard.id%>" onclick="<%= remote_function(:update => "fc_"+flashcard.id.to_s,
	      :url => { :controller => :flashcards, :action => :edit_ajax, :id=>flashcard.id }) %>">
	<%= render :partial => 'flashcards/show_part', :locals=> { :flashcard => flashcard } %> 
	<!--- 	<%= render :partial => 'flashcards/edit_part', :locals=> { :fset => @fset, :flashcard => flashcard } %> ---!>
	</div>
<% end %>
</div>

<div class="tag_cloud">
<div id="tags">
	<% for tag in @tags %>
<%= "<span id='tag_"+tag+"' class='tg'>" %>
	<%= tag+link_to_remote('delete', :url => {:action => "delete_tag", :fset => @fset, :tag => tag}, :html => { 	:class=>'tag_delete_link',	:onclick=>'document.getElementById(\'tag_'+tag+'\').style.display="none"'}) %>
	<%= "</span>" %>
	<% end %>
</div>
<div class="clear">&nbsp;</div>
<% remote_form_for(@fset,  :url => add_tag_fset_url(@fset), :html=> {:method=>:post}) do |f| %>
	<%= f.error_messages %>
	<%= f.text_field :tag_list, :value=>"" %>
	<%= f.submit "", {:class => "tagit"} %>
<% end %>
</div>
